Skip to content

Instantly share code, notes, and snippets.

@kidchemical
kidchemical / Movement.cs
Last active May 9, 2024 15:43
(Unity) Third Person Player Movement Script
/*
* Third Person Player Movement Script v1.1 by Ian McCambridge
* :: Free to use always <3 2020 ::
*
* This script pairs with my "Third Person Camera Script" which can be found here:
* https://gist.github.com/kidchemical/b1542ea489c8f2abae3fbd09798dedd4
* FEATURE OUTLINE:
* -Rigidbody required.
* -Plane or Ground must have Tag property set to new tag named "Ground"
* -Freeze X and Z Rotation for player Rigidbody
@i3visio
i3visio / hashcash.py
Created August 9, 2016 21:27
hashcash.py is a clean implementation of a "proof of work" library for Python.
# ----------------------------------------------
# hashcash.py: Hashcash implementation
# ----------------------------------------------
"""
Hashcash is a "proof of work."
Example:
>>> import sha
>>> sha.new('denmark2890CF').hexdigest() '000000cf89643370c24e413ec0886ab92bd7f6e8'
@mh-firouzjah
mh-firouzjah / Translator.md
Last active May 9, 2024 15:42
Translate selected text on Linux with ease! Assign a keyboard shortcut to instantly translate and pronounce selected texts. 🌐📝

Text Translator and Pronunciation Tool

This script provides a convenient way to check spelling, pronunciation, and translation of words or text using a dictionary (such as Google Translate) directly from your Linux desktop. It can be easily integrated with a keyboard shortcut, making it globally accessible for quick translation and pronunciation of selected text.

Background

As a non-native English speaker, I often find myself needing to verify the spelling, pronunciation, or translation of words, phrases, or paragraphs using an online dictionary like Google Translate. To streamline this process, I developed a script that allows me to quickly translate and hear the pronunciation of selected text with a simple keyboard shortcut.

How It Works

@rafaeltuelho
rafaeltuelho / openshift-cheatsheet.md
Last active May 9, 2024 15:40
My Openshift Cheatsheet

My Openshift Cheatsheet

Project Quotes, Limits and Templates

  • Cluster Quota
oc create clusterquota env-qa \
    --project-label-selector environment=qa \
    --hard pods=10,services=5
    
oc create clusterquota user-qa \
@yoksel
yoksel / gist:a8e9d3a9f740bb9e149f
Last active May 9, 2024 15:39
SVG Symbols Shower Bookmarklet
javascript:void(function(){
var doc = document;
var body = doc.querySelector("body");
var head = doc.querySelector("head");
var icons = "";
var resultElem = doc.querySelector("#icons-shower");
if ( !resultElem ) {
@bruce-willis
bruce-willis / yunohost-oracle-free-tier.md
Last active May 9, 2024 15:39
How to setup YunoHost at Oracle free tier VM
  1. Register for Oracle Cloud Free Tier
  2. Create compute instance
    • change image to Canonical Ubuntu
    • confirm that a public IPv4 address is assigned
    • upload your public ssh key
    • leave everything blank in Boot volume
  3. Enable Internet Access
    • Instances → Instance details → Subnet → Default Security List → Add Ingress Rules
    • HTTP: Stateless: Checked
@Keshav13142
Keshav13142 / .obsidian.vimrc
Last active May 9, 2024 15:40
obsidian-vimrc
" Have j and k navigate visual lines rather than logical ones
nmap j gj
nmap k gk
" Go to beginning/end of line
nmap gh ^
nmap gl $
" Cycle between tabs
exmap tabprev obcommand workspace:previous-tab
@mattifestation
mattifestation / CertTBSHash.ps1
Created September 7, 2017 01:13
Calculates a ToBeSigned hash of a certificate, producing the same uniquely identifying hash present in code integrity rule sets.
# Example: ls 'C:\Windows\System32\*' -Include '*.dll' | Get-AuthenticodeSignature | Select -ExpandProperty SignerCertificate | Get-TBSHash
filter Get-TBSHash {
[OutputType([String])]
param (
[Parameter(Mandatory, ValueFromPipeline)]
[Security.Cryptography.X509Certificates.X509Certificate2]
$Certificate
)
@Faria-Ejaz
Faria-Ejaz / Map.js
Last active May 9, 2024 15:40
react Leaflet Map with Auto-suggest Search #leaflet #react-leaflet #search
/** @format */
import { Map, TileLayer, Marker, Popup } from "react-leaflet";
import React, { useEffect, useState, useRef } from "react";
import { geosearch } from "esri-leaflet-geocoder";
import "leaflet/dist/leaflet.css";
import "esri-leaflet-geocoder/dist/esri-leaflet-geocoder.css";
import L from "leaflet";
function MapView(props) {